<!DOCTYPE html>

<html>

<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1" />
<link rel="stylesheet" type="text/css" href="style.css">
<title>Captive</title>
<script type="text/javascript" src="jquery-1.9.1.min.js"></script>


<script>
	
	$(document).ready(
		function() {
			document.getElementById("dialog").style.display="inherit";
			document.getElementById("background").style.display="inherit";
			document.getElementById("dialog").innerHTML = "(I wake up in the hospital)";
			$("#dialog").click(dialog1);
		}
	);
	
	function dialog1()
	{
		document.getElementById("dialog").innerHTML = "Where am I.....(chest aching)....the kidnapping...Jimmy....";
		$("#dialog").click(dialog2);
	}
	
	function dialog2()
	{
		document.getElementById("dialog").innerHTML = "The kidnapper....why did he say he knows me?";
		$("#dialog").click(dialog3);
	}
	
	function dialog3()
	{
		document.getElementById("dialog").innerHTML = "Oh god....Jimmy....where are you.....";
		$("#dialog").click(endscene);
	}
	
	function endscene()
	{
		$("#dialog").unbind('click');
		$("#dialog").fadeOut(5000,nextscene);
	}
	
	function nextscene()
	{
		window.location = "theend.php";
	}
	
</script>



</head>

<body>


<div id="container">
	<div id="background"><img src="images/hospital.jpg" /></div>
	<div id="dialog">
	</div>
	
</div>



</body>
</html>